﻿<UserControl x:Class="ManagerWpf.Controls.Welcome"
    xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
		xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml" 
		xmlns:d="http://schemas.microsoft.com/expression/blend/2006" 
		xmlns:mc="http://schemas.openxmlformats.org/markup-compatibility/2006" 
		mc:Ignorable="d">
	<UserControl.Resources>
				<Style x:Key="WelcomeButtonStyle" TargetType="{x:Type Button}">
			<Setter Property="Foreground" Value="#FFFFFF" />
			<Setter Property="Width" Value="Auto"/>
			<Setter Property="FontSize" Value="16"/>
			<Setter Property="FontFamily" Value="Calibri"/>
			<Setter Property="FontWeight" Value="Bold"/>
			<Setter Property="Template">
				<Setter.Value>
					<ControlTemplate TargetType="{x:Type Button}">
						<Border x:Name="bd" CornerRadius="3,3,3,3" Padding="5,0,0,0">
							<ContentPresenter SnapsToDevicePixels="{TemplateBinding SnapsToDevicePixels}" VerticalAlignment="{TemplateBinding VerticalContentAlignment}" RecognizesAccessKey="True" Margin="5,1,0,1"/>
						</Border>
						<ControlTemplate.Triggers>
							<Trigger Property="IsKeyboardFocused" Value="true"/>
							<Trigger Property="IsMouseOver" Value="true">
								<Setter Property="Cursor" Value="Hand"/>
								<Setter Property="Background" TargetName="bd" Value="#FF29367B"/>
							</Trigger>
						</ControlTemplate.Triggers>
					</ControlTemplate>
				</Setter.Value>
			</Setter>
		</Style>

		<Style x:Key="RecentFileButtonStyle" TargetType="{x:Type Button}">
			<Setter Property="Foreground" Value="#FFFFFF" />
			<Setter Property="Width" Value="Auto"/>
			<Setter Property="FontSize" Value="16"/>
			<Setter Property="FontFamily" Value="Calibri"/>
			<Setter Property="FontWeight" Value="Bold"/>
			<Setter Property="Template">
				<Setter.Value>
					<ControlTemplate TargetType="{x:Type Button}">
						<Border x:Name="bd" CornerRadius="3,3,3,3" Padding="20,0,0,0">
							<ContentPresenter SnapsToDevicePixels="{TemplateBinding SnapsToDevicePixels}" VerticalAlignment="{TemplateBinding VerticalContentAlignment}" RecognizesAccessKey="True" Margin="5,1,0,1"/>
						</Border>
						<ControlTemplate.Triggers>
							<Trigger Property="IsKeyboardFocused" Value="true"/>
							<Trigger Property="IsMouseOver" Value="true">
								<Setter Property="Cursor" Value="Hand"/>
								<Setter Property="Background" TargetName="bd" Value="#FF29367B"/>
							</Trigger>
						</ControlTemplate.Triggers>
					</ControlTemplate>
				</Setter.Value>
			</Setter>
		</Style>

	</UserControl.Resources>
	<StackPanel>

		<!-- Header -->
		<Border Width="300" Padding="5,0,5,0" Opacity="0.8" x:Name="Header" Background="{DynamicResource WelcomeBackgroundBrush}" BorderBrush="{DynamicResource BorderBrush}" BorderThickness="1,1,1,0" CornerRadius="5,5,0,0" HorizontalAlignment="Center" >
			<Grid>
				<Rectangle Fill="{DynamicResource WelcomeHeaderBg}" Height="69"/>
				<TextBlock Padding="4,0,0,0" Text="Welcome" TextWrapping="Wrap" Foreground="{DynamicResource WelcomeHeaderFontColor}" FontSize="18" FontWeight="Bold" x:Name="HeaderTextBlock" d:LayoutOverrides="Height" HorizontalAlignment="Left" Margin="3.5,0,0,2" VerticalAlignment="Bottom"/>
      </Grid>
		</Border>

		<!-- Content -->
		<Border BorderBrush="{DynamicResource BorderBrush}" BorderThickness="1,1,1,1">
			<Grid Margin="0,0,0,0" x:Name="ContentGrid" Background="{DynamicResource InputBackgroundBrush}">

				<Grid.RowDefinitions>
					<RowDefinition Height="Auto"/>
					<RowDefinition Height="*"/>
				</Grid.RowDefinitions>
				<StackPanel HorizontalAlignment="Stretch" Margin="5,20,5,10">
					<TextBlock Padding="4,0,0,0" Text="Please enter the manager password:" TextWrapping="Wrap" Foreground="{DynamicResource WelcomeHeaderFontColor}" FontSize="14" FontWeight="Bold" x:Name="PasswordTextBlock" d:LayoutOverrides="Height" HorizontalAlignment="Left" Margin="3.5,0,0,2" VerticalAlignment="Bottom"/>
					<TextBox x:Name="txtPassword" Width="200" />
					<Button Margin="0,0,0,5" x:Name="ImportButton" Content="Login   " Click="LoginButton_Click" HorizontalAlignment="Right" Style="{DynamicResource WelcomeButtonStyle}" Width="Auto"/>
				</StackPanel>

				<GridSplitter IsEnabled="False" HorizontalAlignment="Stretch" VerticalAlignment="Bottom" Height="1" Background="#FF3D4976" Margin="2,0,2,0"/>
				
				
				<StackPanel HorizontalAlignment="Stretch" VerticalAlignment="Stretch" Grid.Row="1" x:Name="RecentFilesStackPanel" Margin="5,30.87,5,10"/>

			</Grid>
		</Border>

		<!-- Footer -->
		<Border Background="{DynamicResource BackgroundBrush}" Height="35" x:Name="Footer" Opacity="0.8" BorderBrush="{DynamicResource BorderBrush}" BorderThickness="1,0,1,1" CornerRadius="0,0,5,5">
			<Label x:Name="VersionLabel" Margin="10,0,0,0" Foreground="#FFB5C8D8" Content="Version "/>
		</Border>

	</StackPanel>
</UserControl>
